package view.progress
{
	import controller.signal.FileUploadChangeSignal;
	import controller.signal.FileUploadProgressSignal;
	
	import subumbo.leg.view.ViewComponentMediator;

	public class ProgressMediator extends ViewComponentMediator {
		
		[Inject] public var view:Progress;
		[Inject] public var progress:FileUploadProgressSignal;
		[Inject] public var update:FileUploadChangeSignal;
		 
		public override function onRegister():void {
			_view = view;
			progress.add(view.setProgress);
			update.add(_view.update);
			super.onRegister();
		} 
		
		public override function onRemove():void {
			progress.removeAll();
			update.removeAll();
			_view.destroy();
			super.onRemove();
		}
	}
}